<?php
header("Content-type:text/html;charset=utf-8");
include "index.php";
$catid=intval($_GET['catid']);
$sql=mysql_query("select * from artical where catagory=$catid");
?>
<style>
    .wen{width: 1000px; height: 300px; background: #fff;margin: 0 auto;}
    h3{border-bottom:1px solid #EFEFEF;height: 40px;padding-top: 15px;
        text-indent: 2em;margin: 0; margin-top: 10px;}
    h3 a{color: #83C327;text-decoration: none; }
    h3 a:hover{color:#FF6601;text-decoration: underline;}
    ul li a{color: #000;text-decoration: none;}
    ul li a:hover{color:#A50102;text-decoration: underline;}
    .wen li{margin-left: 30px;line-height:60px; }
</style>
<div style="width: 100%">
    <div class="wen">
        <h3><a href="">励志文章</a></h3>
        <?php
        while($a=mysql_fetch_assoc($sql)){
            ?>
            <ul>
                <li><a href="show.php?artid=<?php echo $a['id'] ?>"><?php echo $a['title'] ?></a></li>
            </ul>

            <?php
        }
        ?>
    </div>
</div>
